<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags" %> 
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    <title>My JSP 'index.jsp' starting page</title>
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">

	<link rel="stylesheet" type="text/css" href="css/style.css">
	    <link rel="stylesheet" type="text/css" href="css/960.css">
	<link rel="stylesheet" type="text/css" href="css/reset.css">
	<link rel="stylesheet" type="text/css" href="css/text.css">
	<link rel="stylesheet" type="text/css" href="css/listNews.css">
	
	<script type="text/javascript" src="fckeditor/fckeditor.js"></script>
	<script type="text/javascript" src="js/jquery.min.js"></script>
	<script type="text/javascript" src="js/index.js"></script>
  </head>
  
  <body>
<div class="container_12 menu">
	<ul>
	  <li><a href="linkListAction.do?xw">新闻</a></li>
	  <li><a href="linkListAction.do?tzgg">通知公告</a></li>
	  <li><a href="linkListAction.do?wdxz">文档下载</a></li>
	  <li><a href="linkListAction.do?jxgz">教学工作</a></li>
	  <li><a href="linkListAction.do?wxts">温馨提示</a></li>
	  
	  <li><a href="linkListAction.do?xzr">系主任简介</a></li>
	  <li><a href="linkListAction.do?zysz">专业设置</a></li>
	  <li><a href="linkListAction.do?jgsz">机构设置</a></li>
	  <li><a href="linkListAction.do?lxfs">联系方式</a></li>
	  
	  <li><a href="linkListAction.do?jgd">教工党支部</a></li>
	  <li><a href="linkListAction.do?xsd">学生党支部</a></li>
	  <li><a href="linkListAction.do?tzz">团组织</a></li>
	  
	  <li><a href="linkListAction.do?xsh">学生会</a></li>
	  <li><a href="linkListAction.do?jyxx">就业信息</a></li>
	  <li><a href="linkListAction.do?xshd">学生活动</a></li>
	  
	  <li><a href="linkListAction.do?jxtd">教学团队</a></li>
	  <li><a href="linkListAction.do?xsbg">学术报告</a></li>
	  <li><a href="linkListAction.do?hzjl">合作交流</a></li>
	  
	  <li><a href="linkListAction.do?kyxx">科研信息</a></li>
	  <li><a href="linkListAction.do?kylx">科研立项</a></li>
	  <li><a href="linkListAction.do?kygz">科研工作</a></li>
	  <li><a href="linkListAction.do?xslw">学术论文</a></li>
	
	
	  <li><a href="linkIndexAction.do">发布新闻页</a></li>
	  <li><a href="toModifyPassword.do">修改密码</a></li>
	  <li><a href="logoutAction.do">退出登录</a></li>
	</ul>
</div>
    <div class="container_12 cbox" style="padding:10px 0 0 0;">
	<div id = "right" >
		<form action="pubNewsAction.do" method="post" enctype="multipart/form-data" >
			<div style="display: block;width:100%;margin-bottom:10px;"><div style="float:left;">文章标题：<input type="text" id="title" name="news.title" ><span style="color:red">*</span></div>
			<div style="float:left;">文章类别：<select name="news.c_id">
					
					<option value="xw">新闻中心</option>
					<option value="tzgg">通知公告</option>
					<option value="wdxz">文档下载</option>
					<option value="jxgz">教学工作</option>
					<option value="wxts">温馨提示</option>

					<option value="xzr">系主任简介</option>
					<option value="zysz">专业设置</option>
					<option value="jgsz">机构设置</option>
					<option value="lxfs">联系方式</option>
					
					<option value="jgd">教工党支部</option>
					<option value="xsd">学生党支部</option>
					<option value="tzz">团组织</option>
					
					<option value="tmgczy">土木工程专业</option>
					<option value="gcglzy">工程管理专业</option>
					<option value="syzx">实验中心</option>
					
					<option value="sdh">学生会</option>
					<option value="jyxx">就业信息</option>
					<option value="xshd">学生活动</option>
					
					<option value="jxtd">教学团队</option>
					<option value="jxsbg">学术报告</option>
					<option value="hzjl">合作交流</option>
					
					<option value="kyxx">科研信息</option>
					<option value="kylx">科研立项</option>
					<option value="kygz">科研工作</option>
					<option value="xslw">学术论文</option>
			</select><span style="color:red">*</span></div>
			<div style="float:left;">文章作者：<input type="text" id="author" name="news.author"></div>
			<div style="float:left;">发布时间：<input type="text" id="datetime" name="news.p_time"></div>
			</div>
			<textarea rows="10" cols="60" name="news.content" enctype="multipart/form-data" id="content" ></textarea>
			<div style="float:left;width:220px;">设置成首页图片新闻：<input type="radio" value="1" id="hoty" name="news.hot" onchange="show()">是
			<input type="radio" value="0" id="hotn" name="news.hot" onchange="hide()" checked="checked">否<br>
			<div id="imgurl" style="display:none;">图片链接地址：<input type="text" name="news.imgurl" ><br></div>
			</div>
			<input id="submit" type="submit" value="发布" style="float:right;height: 50px;width:200px;background: #40aa52;color:#000;font-size: 20px;border:none;cursor:hand;"><br>
	</form>
	</div>
	</div>
<script type="text/javascript">
	window.onload=function(){
	var oFCKeditor = new FCKeditor('news.content') ;
	oFCKeditor.BasePath = "fckeditor/";
	oFCKeditor.ReplaceTextarea();
	}
</script>
	<!--检查必填选项是不是为空，并设置默认值  -->
<script type="text/javascript">
	//检查必填选项是不是为空，并设置默认值
	$(document).ready(function(){
	setValue();
	});
</script>
<script type="text/javascript">
function show(){
	if($("#hoty").val()=='1'){
	$("#imgurl").css("display","");
	}
}
function hide(){ if($("#hotn").val()=='0'){
		$("#imgurl").css("display","none");
	}
}

</script>
</body>
</html>
